package demo1210.pm.pm1;

public class Student {
    String name;
    int stuId;
    static String className;//班级名称

    public Student(String name, int stuId) {
        this.name = name;
        this.stuId = stuId;
    }

    public void show() {
        System.out.println("姓名:" + this.name);
        System.out.println("学号:" + stuId);
        System.out.println("班级名称:" + Student.className);
    }

    public static void sort(int[] arr) {
        System.out.println(className);
        for (int i = 0; i < arr.length - 1; i++) {
            for (int j = 0; j < arr.length - 1 - i; j++) {
                if (arr[j] > arr[j + 1]) {
                    int temp = arr[j];
                    arr[j] = arr[j + 1];
                    arr[j + 1] = temp;
                }

            }
        }

    }
}
